﻿using UnityEditor;
using UnityEngine;

[CanEditMultipleObjects, CustomEditor(typeof(GameSetting))]
public class GameSettingEditor : Editor
{
	public override void OnInspectorGUI()
	{
		this.serializedObject.Update();
        var logTag = this.serializedObject.FindProperty("LogTag");
        var ret = (Logcat.Tag)EditorGUILayout.EnumPopup(new GUIContent("Log"), (Logcat.Tag)logTag.intValue);
        if(ret != Logcat.Tag.none)
        {
            Builder.AddEnableLogDefineSymbols();
        }
        else
        {
            Builder.RemoveEnableLogDefineSymbols();
        }
        logTag.intValue = (int)ret;
        serializedObject.ApplyModifiedProperties();
	}
}